package com.tianquan.common.message;

import com.tianquan.common.instance.ServiceInstance;

import java.util.Map;
import java.util.Set;

/**
 *@Author: tianquan
 *@date: 2024-11-03  16:58
 *@Description: 拉取服务响应消息
 */
public class PullServiceResponseMessage extends AbstractResponseMessage {

    private final Map<String, Set<ServiceInstance>> instances;

    public PullServiceResponseMessage(boolean success, Object reason, Map<String, Set<ServiceInstance>> instances) {
        super(success, reason);
        this.instances = instances;
    }

    public Map<String, Set<ServiceInstance>> getInstances() {
        return instances;
    }

    @Override
    public int getMessageType() {
        return Message.PullServiceResponseMessage;
    }

}
